﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.ComponentModel.DataAnnotations;

namespace MyPSDALayer
{
    [MetadataType(typeof(CaseBaseMetaData))]
    public partial class CaseBas
    {
        private class CaseBaseMetaData
        {
            [Required(ErrorMessage = "案例标题不能 为空")]
            [Display(Name = "案例标题")]
            public string CaseName { get; set; }
            [Required(ErrorMessage="内容不能为空")]
            [Display(Name = "案例描述")]
            public string Descr { get; set; }
            [Display(Name = "是否显示到首页")]
            public string IsIndex { get; set; }
            [Display(Name = "案例类型")]
            public string TypeName { get; set; }
            [Required(ErrorMessage = "请选择图片")]
            [FileFormat("jpg,bmp,gif")]
            [Display(Name = "封面图片")]
            public string CoverUrl { get; set; }
        }
    }
}
